package lab02.test17;

import java.util.Scanner;

/**
 * Created by 123 on 2017/10/27.
 */
public class Test17 {
    public static void main(String[] args) {
        int[] arr = new int[10];


        Scanner sc = new Scanner(System.in);

        for (int i = 0; i < arr.length; i++) {
            arr[i] = sc.nextInt();
        }


        int sum = 0;

        int max = arr[0];
        int min = arr[0];
        int maxOlder=0;
        int minOlder=0;

        for ( int  i = 0; i <arr.length ; i++) {
            if (arr[i]>max){
                max=arr[i];
                maxOlder=i;

            }
        }


        for (int i = 0; i < arr.length; i++) {
            sum = sum + arr[i];

        }


        System.out.println("和为"+sum);
        System.out.println("最大值为"+max);
        System.out.println("最小值为"+min);

    }
}
